<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <title>九九乘法表</title>
    <style>
        body {
            display: flex;
            justify-content: center;
            align-items: center;
            height: 100vh;
            margin: 0;
            background-color: #f0f0f0;
            font-family: 'Courier New', Courier, monospace;
            font-size: 20px;
        }

        table {
            border-collapse: collapse;
        }

        td {
            width: 150px;
            height: 50px;
            text-align: center;
            border: 2px solid #007bff;
            transition: background-color 0.3s, color 0.3s;
            font-weight: bold;
        }

        td:hover {
            background-color: #007bff;
            color: yellow;
        }
    </style>
</head>
<body>
    <table id="multiplicationTable">
    </table>

    <script>
        function generateMultiplicationTable() {
            const table = document.getElementById('multiplicationTable');
            for (let i = 1; i <= 9; i++) {
                const row = document.createElement('tr');
                for (let j = 1; j <= i; j++) {
                    const cell = document.createElement('td');
                    cell.textContent = `${j}×${i } = ${i * j}`;
                    row.appendChild(cell);
                }
                table.appendChild(row);
            }
        }

        generateMultiplicationTable();
    </script>
</body>
</html>